package simplebanksystem.view.backing;

import java.util.HashMap;

import oracle.adf.controller.TaskFlowId;

import simplebanksystem.view.UIManager;

public class SBSMainPageBean {


    public SBSMainPageBean() {
    }

    private static final HashMap<UIManager.Screen, String> _REGION_MAP;
    static {
        _REGION_MAP = new HashMap<UIManager.Screen, String>(3);
        _REGION_MAP.put(UIManager.Screen.CLIENTS_TABLE,
                        "/WEB-INF/clients-tf.xml#clients-tf");
        _REGION_MAP.put(UIManager.Screen.CLIENT_FORM,
                        "/WEB-INF/clientForm-tf.xml#clientForm-tf");
        _REGION_MAP.put(UIManager.Screen.BALANCES_TABLE,
                        "/WEB-INF/balances-tf.xml#balances-tf");
      _REGION_MAP.put(UIManager.Screen.EDIT_CLIENT,
                      "/WEB-INF/editClientInfo-tf.xml#editClientInfo-tf");
    }

    private UIManager _uiManager;

    public TaskFlowId getDynamicTaskFlowId() {
        return TaskFlowId.parse(_REGION_MAP.get(_uiManager.getSearchScreenFocus()));
    }
    
    

    public void setUiManager(UIManager _uiManager) {
        this._uiManager = _uiManager;
    }

}
